﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Reflection;
using System.Text;
using Amazon.DynamoDBv2.DocumentModel;
using Amazon.DynamoDBv2.Model;

namespace AmazonDynamoDBStub.Helpers
{
    static class DocumentHelper
    {
        public static DynamoDBEntry AttributeValueToDynamoDBEntry(AttributeValue attributeValue)
        {
            return typeof(Document).InvokeMember("AttributeValueToDynamoDBEntry", 
                BindingFlags.Static | BindingFlags.NonPublic | BindingFlags.InvokeMethod, 
                null, null, new object[] { attributeValue }) as DynamoDBEntry;
        }
    }
}
